</body>
</html>
<script type="text/javascript">
    layui.config({
        base: "{:C(JS_BASE_PATH)}"
    }).use(['layer','form','func'], function() {
        var layer = layui.layer,
                form = layui.form(),
                func = layui.func,
                $ = layui.jquery;
        form.on('checkbox(allChoose)', function(data){
            var child = $(data.elem).parents('table').find('tbody input[type="checkbox"]');
            child.each(function(index, item){
                item.checked = data.elem.checked;
            });
            form.render('checkbox');
        });
    });
</script>